from google.appengine.ext import db

class Word(db.Model):
    spelling = db.StringProperty(required=True)
    translations = db.StringListProperty(required=True)
    entry_time = db.DateTimeProperty(required=True, auto_now_add=True)
    owner = db.UserProperty(required=True, auto_current_user_add=True)
    score = db.IntegerProperty(required=True, default=0)

class QuizItem:
    spelling_key = None
    spelling = None
    translation_key = None
    translation = None

    def __init__(self, spelling, spelling_key):
        self.spelling = spelling
        self.spelling_key = spelling_key